package com.xk857.pojo.vo;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import java.io.Serializable;


/**
 * 返回小车状态信息
 * @Author CV大魔王
 * @Date 2020.1.20
 */
@Data
@ApiModel("小车状态")
public class CarStatus implements Serializable {


    @NotNull(message = "小车id不可为空")
    @ApiModelProperty("小车id")
    private Integer carId;


    @NotNull(message = "小车状态不可为空")
    @Pattern(regexp = "^(Start)|(Stop)$",message = "小车状态有误")
    @ApiModelProperty("小车状态: 开启(Start)  停止(Stop)")
    private String carAction;
}
